package org.example.order.service;

import com.github.pagehelper.PageInfo;
import org.example.order.common.GoodFilter;
import org.example.order.entity.Good;
import org.example.order.exception.GoodNotFoundException;
import org.example.order.exception.IllegalGoodFilterException;

public interface GoodService {
    PageInfo<Good> getGoodsByFilter(GoodFilter goodFilter) throws IllegalGoodFilterException;

    Good getGood(Long id);
    void addGood(Good good) throws RuntimeException;
    void deleteGood(Long id) throws GoodNotFoundException;
    void updateGood(Good good) throws GoodNotFoundException;
}
